"use strict";

/**
 * 
 * @desc   两个浮点数相乘
 * @param  {Number}  num1
 * @param  {Number}  num2
 * @return {Number} 
 */
function accMul(num1, num2) {
  var m = 0,
      s1 = num1.toString(),
      s2 = num2.toString();

  try {
    m += s1.split(".")[1].length;
  } catch (e) {}

  ;

  try {
    m += s2.split(".")[1].length;
  } catch (e) {}

  ;
  return Number(s1.replace(".", "")) * Number(s2.replace(".", "")) / Math.pow(10, m);
}

module.exports = accMul;